home *** CD-ROM | disk | FTP | other *** search
/ Amiga Plus 2000 #4 / Amiga Plus CD - 2000 - No. 4.iso / Tools / Dev / Bgui / include / bgui / bgui_cx.h < prev    next >
Encoding:
C/C++ Source or Header  |  2000-05-09  |  4.2 KB  |  109 lines

  1. #ifndef BGUI_CX_H
  2. #define BGUI_CX_H
  3. /*
  4.  * @(#) $Header: /cvsroot/bgui/include/bgui_cx.h,v 41.11 2000/05/09 20:01:47 mlemos Exp $
  5.  *
  6.  * $VER: bgui/bgui_cx.h 41.10 (25.4.96)
  7.  * Commodity class structures and constants.
  8.  *
  9.  * (C) Copyright 1998 Manuel Lemos.
  10.  * (C) Copyright 1996-1997 Ian J. Einman.
  11.  * (C) Copyright 1993-1996 Jaba Development.
  12.  * (C) Copyright 1993-1996 Jan van den Baard.
  13.  * All Rights Reserved.
  14.  *
  15.  * $Log: bgui_cx.h,v $
  16.  * Revision 41.11  2000/05/09 20:01:47  mlemos
  17.  * Merged with the branch Manuel_Lemos_fixes.
  18.  *
  19.  * Revision 41.10  1998/02/25 21:13:45  mlemos
  20.  * Bumping to 41.10
  21.  *
  22.  * Revision 1.1  1998/02/25 17:15:47  mlemos
  23.  * Ian sources
  24.  *
  25.  *
  26.  */
  27.  
  28. #ifndef LIBRARIES_COMMODITIES_H
  29. #include <libraries/commodities.h>
  30. #endif /* LIBRARIES_COMMODITIES_H */
  31.  
  32. /*****************************************************************************
  33.  *
  34.  *      "commodityclass" - BOOPSI commodity class.
  35.  *
  36.  *      Tags: 1861 - 1940               Methods: 661 - 700
  37.  */
  38. #define COMM_Name                       (BGUI_TB+1861)  /* I---- */
  39. #define COMM_Title                      (BGUI_TB+1862)  /* I---- */
  40. #define COMM_Description                (BGUI_TB+1863)  /* I---- */
  41. #define COMM_Unique                     (BGUI_TB+1864)  /* I---- */
  42. #define COMM_Notify                     (BGUI_TB+1865)  /* I---- */
  43. #define COMM_ShowHide                   (BGUI_TB+1866)  /* I---- */
  44. #define COMM_Priority                   (BGUI_TB+1867)  /* I---- */
  45. #define COMM_SigMask                    (BGUI_TB+1868)  /* --G-- */
  46. #define COMM_ErrorCode                  (BGUI_TB+1869)  /* --G-- */
  47.  
  48. /* New Methods. */
  49.  
  50. #define CM_ADDHOTKEY                    (BGUI_MB+661)
  51.  
  52. /* Add a hot-key to the broker. */
  53. struct cmAddHotkey {
  54.         ULONG           MethodID;               /* CM_ADDHOTKEY             */
  55.         STRPTR          cah_InputDescription;   /* Key input description.   */
  56.         ULONG           cah_KeyID;              /* Key command ID.          */
  57.         ULONG           cah_Flags;              /* See below.               */
  58. };
  59.  
  60. /* Flags. */
  61. #define CAHF_DISABLED   (1<<0)  /* The key is added but won't work.         */
  62.  
  63. #define CM_REMHOTKEY                    (BGUI_MB+662) /* Remove a key.      */
  64. #define CM_DISABLEHOTKEY                (BGUI_MB+663) /* Disable a key.     */
  65. #define CM_ENABLEHOTKEY                 (BGUI_MB+664) /* Enable a key.      */
  66.  
  67. /* Do a key command. */
  68. struct cmDoKeyCommand {
  69.         ULONG           MethodID;       /* See above.                       */
  70.         ULONG           cdkc_KeyID;     /* ID of the key.                   */
  71. };
  72.  
  73. #define CM_ENABLEBROKER                 (BGUI_MB+665) /* Enable broker.     */
  74. #define CM_DISABLEBROKER                (BGUI_MB+666) /* Disable broker.    */
  75.  
  76. #define CM_MSGINFO                      (BGUI_MB+667)
  77.  
  78. /* Obtain info from a CxMsg. */
  79. struct cmMsgInfo {
  80.         ULONG           MethodID;       /* CM_MSGINFO                       */
  81.         struct {
  82.                 ULONG  *Type;           /* Storage for CxMsgType() result.  */
  83.                 ULONG  *ID;             /* Storage for CxMsgID() result.    */
  84.                 ULONG  *Data;           /* Storage for CxMsgData() result.  */
  85.         }               cmi_Info;
  86. };
  87.  
  88. /* Possible CM_MSGINFO return codes. */
  89. #define CMMI_NOMORE             (~0L)   /* No more messages.                */
  90. #define CMMI_KILL               (1<<16) /* Remove yourself.         V40     */
  91. #define CMMI_DISABLE            (2<<16) /* You have been disabled.  V40     */
  92. #define CMMI_ENABLE             (3<<16) /* You have been enabled.   V40     */
  93. #define CMMI_UNIQUE             (4<<16) /* Unique violation ocured. V40     */
  94. #define CMMI_APPEAR             (5<<16) /* Show yourself.           V40     */
  95. #define CMMI_DISAPPEAR          (6<<16) /* Hide yourself.           V40     */
  96.  
  97. /*
  98.  *      CM_ADDHOTKEY error codes obtainable using
  99.  *      the COMM_ErrorCode attribute.
  100.  */
  101. #define CMERR_OK                (0L)    /* OK. No problems.                 */
  102. #define CMERR_NO_MEMORY         (1L)    /* Out of memory.                   */
  103. #define CMERR_KEYID_IN_USE      (2L)    /* Key ID already used.             */
  104. #define CMERR_KEY_CREATION      (3L)    /* Key creation failure.            */
  105. #define CMERR_CXOBJERROR        (4L)    /* CxObjError() reported failure.   */
  106.  
  107. #endif /* BGUI_CX_H */
  108.  
  109.